package com.example.mvvmdemo.database.room.mtv;

import androidx.room.Dao;
import androidx.room.Query;

import com.example.mvvmdemo.database.room.DataDao;

import java.util.List;
@Dao
public interface MvDao extends DataDao<Mv> {

    @Query("select * from Mv")
    List<Mv> queryAllData();

    @Query("delete from Mv where id = :id")
    int deleteDataById(String id);

    @Query("delete from Mv")
    int deleteAll();

    @Query("update Mv set id = :id , title = :title , year = :year where num = :updetenum")
    int updateDataById(long updetenum, String id, String title, String year);
}
